﻿@using MvcApplication6.Models;
@using System;
@{
    Layout = null;
}
<!DOCTYPE html>
<html>
<head>
    <title></title>
    <script src="@Url.Content("~/Scripts/jquery-1.4.4.js")" type="text/javascript"></script>
    <script src="@Url.Content("~/Scripts/MyJScript.js")" type="text/javascript"></script>
    <script type="text/javascript">
        $(document).ready(function () {
            $("#button1").click(
                function () {
                    refreshDivs('@Url.Action("Index2", "Default1")');
                });

            $("#button2").click(
                function () {
                    refreshDivs('@Url.Action("Index3", "Default1")');
                });

            $("#button3").click(
                function () {
                    refreshDivs('@Url.Action("Index4", "Default1")');
                });
        });
    </script>
</head>
<body>
    <div id="div1" style="border: 2px double black;">
        @{Html.RenderPartial("_PartialPage1", new PartialPage1ModelEx(DateTime.Now));}
    </div>
    <div id="div2" style="border: 2px double black;">
        @{Html.RenderPartial("_PartialPage2", new PartialPage2ModelEx(DateTime.Now));}
    </div>
    <div>
        <input id="button1" type="button" value="Refresh first" />
        <input id="button2" type="button" value="Refresh second" />
        <input id="button3" type="button" value="Refresh both" />
    </div>
</body>
</html>
